package com.cssl.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.data.annotation.Transient;
import org.springframework.data.mongodb.core.mapping.Document;
import org.springframework.data.mongodb.core.mapping.MongoId;

/**
 * 
 * @TableName emp
 */
@Document("emp")
@TableName(value ="emp")
@Data
@EqualsAndHashCode(of = "empno")
public class Emp implements Serializable {
    /**
     * 
     */
    @MongoId
    @TableId(value = "empno", type = IdType.AUTO)
    private Integer empno;

    /**
     * 
     */
    @TableField(value = "ename")
    private String ename;

    /**
     * 
     */
    @TableField(value = "hiredate")
    private Date hiredate;

    /**
     * 
     */
    @TableField(value = "dept_no")
    private Integer deptNo;

    @Transient
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @TableField(exist = false)
    private Dept dept;
}